-- CALC_GET_SCROLL_BY_RANK

-- 根据阶位获取卷轴id
return function(user, rank)
    rank = math.min(5, rank);

    local rand = DungeonM.getRandSeed("GET_SCROLL_BY_RANK");
    local scrollArr = ItemM.getScrollByRank(rank);
    local classId   = FormulaM.invoke("FETCH_BY_RAND", scrollArr, rand);

    return classId;
end